* {
  margin: 0;
  padding: 0;
  font-size: 100%;
  list-style: none;
}
.menu {
  width: 200px;
  height: 50px;
  background: #409eff;
  color: #fff;
  line-height: 50px;
  margin: 0 auto;
  margin-top: 50px;
  text-align: center;
  cursor: pointer;
  position: relative;
}
.sub-menu {
  background: #ddebfd;
  font-size: 14px;
  line-height: 35px;
  color: #333;
  padding: 10px 0;
  position: absolute;
  width: 100%;
}
.menu {
  border-radius: 5px;
}
.sub-menu {
  border-radius: 5px;
  transform: scaleY(0);
  transition: 0.3s;
  transform-origin: center top;
}
.menu:hover .sub-menu {
  transform: scaleY(1);
}